package dao.impl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.orm.hibernate5.HibernateTemplate;
import org.springframework.orm.hibernate5.support.HibernateDaoSupport;
import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Transactional;

import dao.UserDao;
import domain.User;

@Repository(value="userDao")
@Transactional
public class UserDaoImpl extends HibernateDaoSupport implements UserDao {

	@Autowired
	public void setHT(HibernateTemplate hibernateTemplate) {
		super.setHibernateTemplate(hibernateTemplate);
	}
	@Override
	public void save(User user) {
		this.getHibernateTemplate().save(user);
	}

}
